 <#ftl encoding="UTF-8" />
            <form id="form_data" class="form__data_content">
                <!-- 生产指示书 -->
                <div id="panelTop" style="position:relative; height:50px; border-bottom: 1px solid #ddd; background-color:#fff;">
                    <div id="btnPanel_01" style="position:absolute; display:inline-block; top:12px; left: 8px; width:auto; padding:0px;">
                        <button type="button" name="_ButBack" id="ButBack" class="act__button" onclick="_InstancePageHeader.DoBack();"><i class="fa-all fa-1x fa-reply" style="margin-right:3px;"></i>返回</button>
                        <button type="button" name="_ButNew" id="ButNew" class="act__button" onclick="_InstancePageHeader.New();"><i class="fa-all fa-1x fa-plus" style="margin-right:3px;"></i>增加</button>
                        <button type="button" name="_ButSave" id="ButSave" data_checked="is" class="act__button act__save" onclick="_InstancePageHeader.Save();"><i class="fa-all fa-1x fa-save" style="margin-right:3px;"></i>保存</button>
                        <button type="button" name="_ButCheck" id="ButCheck" class="act__button" onclick="_InstancePageHeader.DoCheck();"><i class="fa-all fa-1x fa-eye" style="margin-right:3px;"></i>审核</button>
                        <button type="button" name="_ButUnCheck" id="ButUnCheck" class="act__button" onclick="_InstancePageHeader.Uncheck();"><i class="fa-all fa-1x fa-eraser" style="margin-right:3px;"></i>反审</button>
                        <button type="button" name="_ButPrint" id="ButPrint" class="act__button" onclick="_InstancePageHeader.DoPrintPreview();"><i class="fa-all fa-1x fa-print" style="margin-right:3px;"></i>打印预览</button>
                        <div id="ButOverSwitcher" class="switcher" style="position:relative; top:-4px; left:50px;">
                            <input class="switcher__input" type="checkbox" name="_OverFlag" id="OverFlag" onclick="_InstancePageHeader.SetOverFlag();">
                            <label class="switcher__label" for="OverFlag">
                                <span class="switcher__text">完成</span>
                            </label>
                        </div>
                    </div>
                    <div id="rec_position" style="position:absolute; display:inline-block; right:80px; top:18px; width:auto;">
                        <span id="rec_cur_row">15</span> / <span id="rec_total_rows">15</span>
                    </div>
                    <div class="panel__toolbar" style="position:absolute; display:inline-block; top:12px; right:20px;">
                        <div class="panel__toolbar_item">
                            <button type="button" class="toolbar__button" name="_ButPrev" id="ButPrev" title="前一条" onclick="_InstancePageHeader.PrevRecord();"><i class="fa-all fa-1x fa-angle-left" style="margin-right:3px;"></i></button>
                        </div>
                        <div class="panel__toolbar_item" disabled="disabled">
                            <button type="button" class="toolbar__button" name="_ButNext" id="ButNext" title="后一条" onclick="_InstancePageHeader.NextRecord();"><i class="fa-all fa-1x fa-angle-right" style="margin-right:3px;"></i></button>
                        </div>
                    </div>
                </div>
                <div class="data__table_wrapper">
                    <table class="data__table">
                        <colgroup>
                            <col style="width: 7%;" />
                            <col style="width: 15%;" />
                            <col style="width: 7%;" />
                            <col style="width: 13%;" />
                            <col style="width: 7%;" />
                            <col style="width: 15%;" />
                            <col style="width: 7%;" />
                            <col />
                        </colgroup>
                        <tbody>
                            <tr>
                                <td class="td__label">
                                    <label for="ContractNo">合同号<em>★</em></label>
                                </td>
                                <td>
                                    <input type="text" id="ContractNo" name="_ContractNo" tabindex="1" style="width:98%;" />
                                </td>
                                <td class="td__label">
                                    <label for="SuitNoOfStyle">款号<em>★</em></label>
                                </td>
                                <td colspan="3">
                                    <div id="ChoiceStyleNo" class="form_input_dropdown_wrapper" style="width:100%;" onclick="_InstancePageHeader.DoChoiceStyleNo();">
                                        <input type="text" id="SuitStyleNo" name="_SuitStyleNo" class="select-dropdown with_select_flag" readonly="readonly" tabindex="2" />
                                    </div>
                                </td>
                                <td class="td__label">
                                    <label for="CustomerName">客户名称</label>
                                </td>
                                <td>
                                    <input type="text" id="CustomerName" name="_CustomerName" tabindex="3" readonly="readonly" style="width:100%;" />
                                </td>
                            </tr>
                            <tr>
                                <td class="td__label">
                                    <label for="IssueDate">下达日期<em>★</em></label>
                                </td>
                                <td>
                                    <div id="ChoiceIssueDate" class="form_input_dropdown_wrapper" style="width:135px;">
                                        <input type="text" id="IssueDate" name="_IssueDate" class="select-dropdown" tabindex="4" />
                                        <span class="dropdown_button"><i class="fa-all fa-1-1 fa-calendar"></i></span>
                                    </div>
                                </td>
                                <td class="td__label">
                                    <label for="SaledByName">贸易担当<em>★</em></label>
                                </td>
                                <td>
                                    <input type="hidden" id="SaledBy" name="_SaledBy" value="0" tabindex="5"/>
                                    <div id="ChoiceSaledBy" class="form_input_dropdown_wrapper" style="width:135px;" onclick="_InstancePageHeader.DoChoiceSaledBy();">
                                        <input type="text" id="SaledByName" name="_SaledByName" class="select-dropdown with_select_flag" readonly="readonly" tabindex="5" />
                                    </div>
                                </td>
                                <td class="td__label">
                                    <label for="TradeModeName">贸易形式<em>★</em></label>
                                </td>
                                <td>
                                    <input type="hidden" id="TradeModeId" name="_TradeModeId" value="0" tabindex="6"/>
                                    <div id="ChoiceTradeMode" class="form_input_dropdown_wrapper" style="width:100%;" onclick="_InstancePageHeader.DoChoiceTradeMode();">
                                        <input type="text" id="TradeModeName" name="_TradeModeName" class="select-dropdown with_select_flag" readonly="readonly" tabindex="6" />
                                    </div>
                                </td>
                                <td class="td__label">
                                    <label for="SettlementModeName">结算方式<em>★</em></label>
                                </td>
                                <td>
                                    <input type="hidden" id="SettlementModeId" name="_SettlementModeId" value="0" tabindex="7"/>
                                    <div id="ChoiceSettlementMode" class="form_input_dropdown_wrapper" style="width:100%;" onclick="_InstancePageHeader.DoChoiceSettlementMode();">
                                        <input type="text" id="SettlementModeName" name="_SettlementModeName" class="select-dropdown with_select_flag" readonly="readonly" tabindex="7" />
                                    </div>
                                </td>
                            </tr>
                            <tr>
                                <td class="td__label">
                                    <label for="TotalQuantity">合同数</label>
                                </td>
                                <td>
                                    <input type="text" id="TotalQuantity" name="_TotalQuantity" tabindex="8" readonly="readonly" />
                                </td>
                                <td class="td__label">
                                    <label for="SampleQuantity">样品数</label>
                                </td>
                                <td>
                                    <input type="text" id="SampleQuantity" name="_SampleQuantity" readonly="readonly" tabindex="9" />
                                </td>
                                <td class="td__label">
                                    <label for="UpdatedByName">操作情况</label>
                                </td>
                                <td>
                                    <input type="text" id="UpdatedByName" name="_UpdatedByName" readonly="readonly" tabindex="10" value="<#if identityUser?exists>${identityUser.getEmployeeName()}</#if>"/ style="width:80px;">
                                    <input type="text" id="UpdatedDate" name="_UpdatedDate" readonly="readonly" tabindex="11" style="width:80px;" />
                                </td>
                                <td class="td__label">
                                    <label for="CheckedByName">审核情况</label>
                                </td>
                                <td>
                                    <input type="hidden" id="CheckedBy" name="_CheckedBy" />
                                    <input type="text" id="CheckedByName" name="_CheckedByName" readonly="readonly" tabindex="12" style="width:80px;" />
                                    <input type="text" id="CheckedDate" name="_CheckedDate" readonly="readonly" tabindex="13" style="width:80px;" />
                                </td>
                            </tr>
                            <tr>
                                <td class="td__label" style="vertical-align:top; padding-top:8px;">
                                    <label for="Description">备注</label>
                                </td>
                                <td colspan="7">
                                    <textarea class="area" id="Description" name="_Description" rows="4" tabindex="14" style="width:100%; height:72px; resize:none;"></textarea>
                                </td>
                            </tr>
                        </tbody>
                    </table>
                </div>
            </form>
     
            <input id="Action" type="hidden" value="<#if action?exists>${action}<#else>0</#if>" />
            <input id="HeaderId" type="hidden" value="<#if moId?exists>${moId}<#else>0</#if>" />
            <input id="PictureUrl" type="hidden" value="<#if strImageUrl?exists>${strImageUrl}<#else>0</#if>" />
            <input id="QuotedFlag" type="hidden" value="" />
            <div style="position:absolute; top:13px; right:200px;">
                <span id="CheckedTip" class="huzo_status huzo_status__green">状态：已审核</span>
            </div>
     
            <!-- 明细部分 -->
            <div id="panelSlave" style="position:relative; top:0px;">
                <!-- 折叠标记 -->
                <div id="hPanelSplitter" title="隐藏主表"><i class="fa-all fa-angle-double-up"></i></div>
                <!-- 明细内容 -->
                <ul id="tabPanelHeader" class="tabstrip" style="top:0px; width:100%">
                    <li id="menu_01" class="tabInactive" style="margin-left:25px;">
                        <div>
                            <span class="tab_stretch"><span class="tabtext"><abbr class="ls_01">生产指示书明细</abbr></span></span>
                        </div>
                    </li>
                    <li id="menu_02">
                        <div>
                            <span class="tab_stretch"><span class="tabtext"><abbr class="ls_02">产品图片</abbr></span></span>
                        </div>
                    </li>
                </ul>
                <div id="tabPanelData" class="tab__wrapper" style="top:0px; height:auto;">
                    <div id="tabWrapper_01" class="tab__content" style="padding-top:5px; width:100%;">
                        <div id="panelSlaveButton_01" style="clear:both; position:relative; top:3px; padding-left:8px; z-index:+1;">
                            <button type="button" name="_ButNewLines" id="ButNewLines" data_checked="is" class="act__button act__save" onclick="_InstancePageLines.NewLines();"><i class="fa-all fa-1x fa-plus" style="margin-right:3px;"></i>增加</button>
                            <button type="button" name="_ButSaveLines" id="ButSaveLines" data_checked="is" class="act__button act__save" onclick="_InstancePageLines.SaveLines();"><i class="fa-all fa-1x fa-save" style="margin-right:3px;"></i>保存</button>
                            <button type="button" name="_ButDeleteLines" id="ButDeleteLines" data_checked="is" class="act__button act__save" onclick="_InstancePageLines.BatchDeleteLines();" style="margin-right:15px;"><i class="fa-all fa-1x fa-minus" style="margin-right:5px;"></i>批量删除</button>
                            <!--button type="button" name="_ButAddSize" id="ButAddSize" data_checked="is" class="act__button act__save" onclick="_InstancePageLines.AddNewSizePerColour();">增加尺码</button-->
                            <button type="button" name="_ButAddColour" id="ButAddColour" data_checked="is" class="act__button act__save" onclick="_InstancePageLines.AddNewColourLines();">增加颜色</button>
                            <button type="button" name="_ButUpdateLinesColour" id="ButUpdateLinesColour" data_checked="is" class="act__button act__save" onclick="_InstancePageLines.BatchUpdateLinesColour();">改变颜色</button>
                            <button type="button" name="_ButUpdateLinesColourOrder" id="ButUpdateLinesColourOrder" data_checked="is" class="act__button act__save" onclick="_InstancePageLines.UpdateLinesColourOrder();">改变颜色顺序</button>
                            <button type="button" name="_ButUpdateLinesMarkNo" id="ButUpdateLinesMarkNo" data_checked="is" class="act__button act__save" onclick="_InstancePageLines.BatchUpdateLinesMarkNo();" style="margin-left:15px;">批量编辑唛头号</button>
                            <button type="button" name="_ButUpdateDeliveryDate" id="ButUpdateDeliveryDate" data_checked="is" class="act__button act__save" onclick="_InstancePageLines.UpdateDeliveryDate();">修改交付日期</button>
                            <button type="button" name="_ButUpdateDestination" id="ButUpdateDestination" data_checked="is" class="act__button act__save" onclick="_InstancePageLines.UpdateDestination();">编辑发送地</button>
                        </div>
                        <div id="panelSlaveData_01" style="position:relative; top:10px; margin:0 8px;">
                            <table style="width:100%;">
                                <tr>
                                    <td style="overflow:hidden; width:593px;">
                                        <div id="divH11" style="overflow:hidden; border:none;">
                                            <table id="tabHeader11" class="layout display" style="width:100%;">
                                                <colgroup>
                                                    <col style="width: 27px;" />
                                                    <col style="width: 36px;" />
                                                    <col style="width: 90px;" />
                                                    <col style="width: 200px;" />
                                                    <col style="width: 150px;" />
                                                    <col style="width: 90px;" />
                                                </colgroup>
                                                <thead>
                                                    <tr>
                                                        <th>
                                                           <label class="btn" for="CheckAll" style="margin-left:3px;"><input id="CheckAll" type="checkbox" onclick="_InstancePageLines.DoCheckAll($(this),'_check_row');" /><i></i><span></span></label>
                                                        </th>
                                                        <th style="text-align:center;">删除</th>
                                                        <th>色号</th>
                                                        <th>颜色</th>
                                                        <th class="edit__column">尺码</th>
                                                        <th>数量</th>
                                                    </tr>
                                                </thead>
                                            </table>
                                        </div>
                                    </td>
                                    <td style="position:relative; vertical-align:top; widht:100%;">
                                        <div id="divH12" class="header__with__margin">
                                            <table id="tabHeader12" class="layout display" style="margin-left:-1px; width:100%;">
                                                <colgroup>
                                                    <col style="width: 120px;" />
                                                    <col style="width: 120px;" />
                                                    <col />
                                                </colgroup>
                                                <thead>
                                                    <tr">
                                                        <th class="edit__column">唛头号</th>
                                                        <th class="edit__column">样品数</th>
                                                        <th class="edit__column">备注</th>
                                                    </tr>
                                                </thead>
                                            </table>
                                        </div>
                                    </td>
                                </tr>
                                <tr>
                                    <td style="vertical-align:top; width:593px;">
                                        <div id="divD11" class="grid__data_wrapper" style="border:none; border-bottom:1px solid #c6c3bd; overflow:hidden;">
                                            <table id="tabData11" class="responsive__table" style="margin-top:-1px;">
                                                <colgroup>
                                                    <col style="width: 27px;" />
                                                    <col style="width: 36px;" />
                                                    <col style="width: 90px;" />
                                                    <col style="width: 200px;" />
                                                    <col style="width: 150px;" />
                                                    <col style="width: 90px;" />
                                                </colgroup>
                                                <tbody></tbody>
                                            </table>
                                        </div>
                                    </td>
                                    <td class="with__border__lines" style="vertical-align:top;">
                                        <div id="divD12" class="grid__data_wrapper" style="left:-1px; overflow:scroll;" onscroll="_InstancePageLines.ScrollTo();">
                                            <table id="tabData12" class="responsive__table" style="margin-top:-1px; margin-left:-1px; border-bottom:1px solid #c6c3bd; width:100%;">
                                                <colgroup>
                                                    <col style="width: 120px;" />
                                                    <col style="width: 120px;" />
                                                    <col />
                                                </colgroup>
                                                <tbody></tbody>
                                            </table>
                                        </div>
                                    </td>
                                </tr>
                            </table>                    
                        </div>
                    </div>
                    <!-- 产品图片-->
                    <div id="tabWrapper_02" class="tab__content" style="padding-top:5px; width:100%;">
                        <div id="panelSlaveButton_02" style="clear:both; position:relative; top:3px; padding-left:8px; z-index:+1;">
                            <button type="button" name="_ButDelPicture" id="ButDelPicture" class="act__button act__save" onclick="_InstancePagePicture.DeletePicture();">删除图片</button>
                            <button type="button" name="_ButViewPicture" id="ButViewPicture" class="act__button" onclick="_InstancePagePicture.ViewPicture();">查看原图</button>
                        </div>
                        <div id="panelSlaveData_02" style="position:relative; top:5px; width:100%; padding:0 8px;">
                            <table id="picEditArea" class="data__table" style="text-align:left;">
                                <colgroup>
                                    <col style="width: 90px;" />
                                    <col />
                                </colgroup>
                                <tbody>
                                    <tr>
                                        <td class="td__label" style="vertical-align:top; text-align:left; padding-left:0px; padding-top:8px;">
                                            <label for="hzUploadFile">产品图片</label>
                                        </td>
                                        <td>
                                            <input id="t_hzUploadFile" type="hidden" value="product" />
                                            <input id="d_hzUploadFile" type="hidden" value="" />
                                            <input id="b_hzUploadFile" type="hidden" value="" />
                                            <input id="download_hzUploadFile" type="hidden" value="" />
                                            <span class="btn__add_pic">
                                                <span><em></em>添加文件</span>
                                                <input type="file" id="hzUploadFile" name="_hzUploadFile" class="field__upload_file" title="支持图片、文本等格式，文件小于5M"
                                                       tabindex="19"
                                                       onchange="onFileInputChange('hzUploadFile');" />
                                            </span>
                                            <span id="filename_hzUploadFile"></span>
                                            <button type="button" id="upload_hzUploadFile" class="act__button act__save" disabled="disabled" onclick="_InstancePagePicture.DoFileUpload();">添加图片</button>
                                            <img id="loading_hzUploadFile" alt="loading" src="${rc.contextPath}/images/icons/loading.gif" style="display:none; vertical-align:middle;" />
                                            <span id="error_hzUploadFile" style="display:none; background-color:Yellow; cursor:pointer; padding:2px;"></span>
                                        </td>
                                    </tr>
                                </tbody>
                            </table>
                            <ul id="ProductPictureList" class="picList" style="background:red;">
                                <li><img src="" alt="产品图片" style="max-width:150px; max-height:120px;" /></li>
                            </ul>
                        </div>
                    </div>
                </div>
            </div>
